package io.datajek.springbasics.movierecommendersystem.Lesson11;


import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Component;
import javax.annotation.PostConstruct;
import javax.annotation.PreDestroy;

@Component
public class ContentBasedFilter implements Filter {
    private Logger logger = LoggerFactory.getLogger(this.getClass());

    public ContentBasedFilter(){
        super();
        logger.info("In ContentBasedFilter constructor method");
    }

    @PostConstruct
    private void postConstruct(){
        logger.info("In ContentBasedFilter postConstruct method");
    }

    @PreDestroy
    private void preDestory(){
        logger.info("In ContentBasedFilter preDestory method");
    }

    public String[] getRecommendations(String movie){
        return new String[] {"Happy Feet","Ice Age","Shark Tale"};
    }
}
